{extend	name="homepage"	/}
{block name="right"}
  <!-- content start -->
  <div class="admin-content">
    <div class="admin-content-body">
      <div class="am-cf am-padding am-padding-bottom-0">
        <div class="am-fl am-cf"><strong class="am-text-primary am-text-lg">商品类型添加</strong> / <small>Personal information</small></div>
      </div>

      <hr/>

      <div class="am-g">
        <div class="am-u-sm-12 am-u-md-4 am-u-md-push-8">
          

        </div>

        <div class="am-u-sm-12 am-u-md-8 am-u-md-pull-4">
          <form action="{:Url('admin/addmodular/tianjia')}" class="am-form am-form-horizontal" enctype="multipart/form-data"	method="post">

            <label for="user-name" class="am-u-sm-3 am-form-label">上级分类 </label>          
            <select name="pid" id='pid' style="width:100px;margin:10px 10px 10px 30px" onchange="first(this)">
               <option value="">请选择</option>
               {volist name="res" id="vo"}
               <option value="{$vo.id}">{$vo.name}</option>
               {/volist}
             </select><br>
 
             <div class="am-form-group">
               <label for="name" class="am-u-sm-3 am-form-label">名称 </label>
               <div class="am-u-sm-9">
                 <input type="text" name="name" placeholder=" " style="margin:0px 0px 0px -20px">
               </div>
             </div>

            
              
            <div class="am-form-group">
              <div class="am-u-sm-9 am-u-sm-push-3">
                <button type="submit" class="am-btn am-btn-primary" onclick="up">添加</button>
              </div>
            </div>
          </form>
        </div>
      </div>
    </div>

    <footer class="admin-content-footer">
      <hr>
      <p class="am-padding-left">© 2014 AllMobilize, Inc. Licensed under MIT license.</p>
    </footer>

  </div>
  <!-- content end -->
  <script>
     function up(){
          $.ajax({
              url:"{:Url('admin/typeshop/tianjia')}",
              data:{name:$('.name').html(),},
              dataType:'html',
              type:'post',
              success:function(data){
              }
                  
          })
      }
  </script>
  {/block}

